package org.rambadger.command.event;


import org.rambadger.command.validation.UrlIdentifier;

import javax.validation.constraints.NotNull;
import java.io.Serializable;

public abstract class PointsAwarded {
    public static class SubmissionPointsAwarded implements Serializable {
        private static final long serialVersionUID = -3194301622973167811L;

        private final String username;
        private final int points;

        public SubmissionPointsAwarded(String username, int points) {
            this.username = username;
            this.points = points;
        }

        @UrlIdentifier @NotNull
        public String getUsername() {
            return username;
        }

        //We may chose to let this be negative
        public int getPoints() {
            return points;
        }

        @Override
        public String toString() {
            return "SubmissionPointsAwarded{" +
                    "username='" + username + '\'' +
                    ", points=" + points +
                    '}';
        }
    }


    public static class ReviewPointsAwarded implements Serializable {
        private static final long serialVersionUID = 3806464656145341390L;

        private final String username;
        private final int points;

        public ReviewPointsAwarded(String username, int points) {
            this.username = username;
            this.points = points;
        }

        @UrlIdentifier @NotNull
        public String getUsername() {
            return username;
        }

        //We may chose to let this be negative
        public int getPoints() {
            return points;
        }

        @Override
        public String toString() {
            return "AwardReviewPoints{" +
                    "username='" + username + '\'' +
                    ", points=" + points +
                    '}';
        }
    }
}
